<%@ page import="java.util.*, javax.sql.*"%>
<%@ taglib uri="http://struts.apache.org/tags-bean" prefix="bean"%>
<%@ taglib uri="http://struts.apache.org/tags-logic" prefix="logic"%>
<%@ taglib uri="http://struts.apache.org/tags-html" prefix="html"%>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html:html>
	<head>
		<title><bean:message key="student.title" /></title>
		<bean:define id="first" name="fname" />
		<bean:define id="middle" name="mname" />
		<bean:define id="last" name="lname" />
		<html:base />
		<link rel="stylesheet" type="text/css" href="../resources/style.css" media="screen"/>
	</head>
<body>
	<p class="sansserif">
	<div class="container">
	<div class="center_div">
	<!-- in case validation of the entry data fails in the data bean -->
	<html:errors />
	
	<table>
	<tr>
		<td><b><bean:message key="student.header" /></b></td>
		<td></td><td></td><td></td>
		<td><a href="../invalidate.jsp">Logout</a></td>
	</tr>
	<tr>
	</tr>
	</table>
	<ul class="none">
		<li>
			Applicant Name: 
				<bean:write name="first"/>
				<bean:write name="middle"/>
				<bean:write name="last"/>
		</li>
	</ul>
	
	<p><b><bean:message key="student.citizen.title" /></b></p>
	<table>
	<%
		Vector count_1 = (Vector)request.getAttribute("countries_1");
		Vector count_2 = (Vector)request.getAttribute("countries_2");
		Vector count_3 = (Vector)request.getAttribute("countries_3");
	%>
	<logic:iterate id="country" name="countries_1" indexId="counter">
		<tr>
			<td>
				<html:link action="/residence">
					<html:param name="citizen" value="<%= (String)count_1.get(counter) %>" />
					<bean:write name="country"/>
				</html:link>	
			</td>
			<td>
				<html:link action="/residence">
					<html:param name="citizen" value="<%= (String)count_2.get(counter) %>" />
					<%= (String)count_2.get(counter) %>
				</html:link>	
			</td>
			<td>
				<html:link action="/residence">
					<html:param name="citizen" value="<%= (String)count_3.get(counter) %>" />
					<%= (String)count_3.get(counter) %>
				</html:link>	
			</td>
		</tr>
	</logic:iterate>
	</table>

	</div>
	</div>
</body>
</html:html>